<!DOCTYPE html>
<html data-ng-controller="mainCtrl">
<head lang="zh">
    <meta charset="UTF-8">
    ${require('mypublic/inc/head.html')}
</head>
<body>
${require('mypublic/inc/seajs.html')}
${require('mypublic/inc/top.html')}
${require('@yunke/core/html/server_time.html')}
<div class="layout">
    <!-- 容器 [[-->
    <div class="container">
        <div class="wrap clearfix">
            <div class="pt10">
                ${require('mypublic/inc/left_side.html')}
            </div>
            <div class="content">

                <div class="section-table mt20">
                    <div class="table-header lh30 pb5 clearfix" id="user-auth">
                        <div class="fr btn-group article-edit-id-wrapper">
                            <button class="btn" id="save">保存</button>
                            <button class="btn" id="save_create">保存并新建</button>
                            <button class="btn" id="save_close">保存并关闭</button>
                            <button ng-show="data.a_id" class="btn btn-yellow" id="save_copy">保存并复制</button>
                            <button class="btn" id="no_save">取消</button>
                        </div>
                    </div>
                    <div class="mt10">
                        <div class="float:left;">
                            <div class="section">
                                <div class="section-span"><span style="color:#ff0000;">* </span>标题：</div>
                                <div><input type="text" ng-model="data.title" name="title" id="title"
                                            class="form-control form-w"></div>
                            </div>
                            <div class="section">
                                <div class="section-span"><span style="color:#ff0000;">* </span>封面图片：</div>
                                <div id="image_load" class="content table-cell">
                                    <div id="upload_button">
                                        <div>+</div>
                                        <p>上传图片</p></div>
                                </div>
                                <div class="image-upload-container">
                                    <div id="preview_container" style="position: relative;"></div>
                                    <div class="controllbar table" style="position: absolute;">
                                        <div class="upload table-cell" style="">重新上传</div>
                                        <div class="cancel table-cell" style="">删除</div>
                                    </div>
                                </div>
                                <div style="display: none;">
                                    <form action="#" enctype="multipart/form-data" method="post"
                                          role="image-upload-file-form">
                                        <input name="file" role="image-upload-file-input" accept="image/*"
                                               style="display:none;"
                                               type="file">
                                    </form>
                                </div>

                                <input type="hidden" name="image_url" id="image_url" value="{{data.image_url}}">
                            </div>
                            <div class="section">
                                <div class="section-span"><span style="color:#ff0000;">* </span>作者：</div>
                                <div><input type="text" ng-value="data.author" name="author" id="author"
                                            class="form-control form-w"></div>
                            </div>
                            <div class="section">
                                <div class="section-span"><span style="color:#ff0000;">* </span>标签：</div>
                                <div><input type="text" ng-value="data.tag" name="tag" id="tag"
                                            class="form-control form-w"><span>   多个标签时，请以中文逗号“，”隔开，如“视频，培训，移动销售”</span>
                                </div>
                            </div>
                            <div class="section">
                                <div class="section-span"><span style="color:#ff0000;">* </span>目录：</div>
                                <div>
                                    <select id="dir_id" class="form-control form-w" name="dir_id">
                                        <option
                                                ng-repeat="(key,item) in data.dirs"
                                                value="{{key}}"
                                                ng-selected="{{data.dir_id===key}}"
                                        >
                                            {{item}}
                                        </option>
                                    </select>
                                </div>
                            </div>
                            <div class="section">
                                <div class="section-span">原文链接：</div>
                                <div><input type="text" ng-value="data.link_url" name="link_url" id="link_url"
                                            class="form-control form-w"></div>
                            </div>

                            <div class="section">
                                <div class="section-span">附件：</div>
                                <div style="float: left;">
                                    <div id="file_load">
                                        <div id="file_upload_button" class="btn">上传</div>
                                    </div>
                                    <div id="file_list">
                                    </div>
                                </div>
                                <div style="display: none;">
                                    <form action="#" enctype="multipart/form-data" method="post"
                                          role="file-upload-file-form">
                                        <input name="file[]" role="file-upload-file-input" style="display:none;"
                                               type="file" multiple>
                                    </form>
                                </div>

                                <input type="hidden" name="file_url" id="file_url" value="">
                                <input type="hidden" name="file_name" id="file_name" value="">
                            </div>

                            <input type="hidden" name="a_id" id="a_id" ng-value="data.a_id">
                        </div>
                        <div style="width:750px;float:left;">
                            <script type="text/plain" id="meEditor"></script>
                        </div>
                    </div>
                </div>


            </div>
        </div>
    </div>
    <!-- 容器 ]]-->
</div>
</body>
${require('@yunke/core/public_menu/footer.html')}
<script type="text/javascript" src="./index.js"></script>
</html>
